package cn.zzdt4j.auth.service;

import cn.zzdt4j.auth.model.biz.user.UserQueryPageReqDTO;
import cn.zzdt4j.auth.model.biz.user.UserReqDTO;
import cn.zzdt4j.auth.model.biz.user.UserRespDTO;
import com.baomidou.mybatisplus.core.metadata.IPage;

import java.util.List;

/**
 * @author by <a href="mailto:ligang941012@gmail.com">gang.Li</a>
 * @since 2023/10/30 0:13
 */
public interface UserService {

    /**
     * Paging query user list.
     *
     * @param requestParam request param
     * @return user response page
     */
    IPage<UserRespDTO> listUser(UserQueryPageReqDTO requestParam);

    /**
     * New users.
     *
     * @param requestParam request param
     */
    void addUser(UserReqDTO requestParam);

    /**
     * Modify user.
     *
     * @param requestParam request param
     */
    void updateUser(UserReqDTO requestParam);

    /**
     * Delete users.
     *
     * @param username username
     */
    void deleteUser(String username);

    /**
     * Fuzzy search by username.
     *
     * @param userName userName
     * @return like username
     */
    List<String> getUserLikeUsername(String userName);

    /**
     * Get user details.
     *
     * @param requestParam request param
     * @return user response
     */
    UserRespDTO getUser(UserReqDTO requestParam);
}
